const umfUtils = require('../../utils/UmfUtils.js');
const umfToast = require('../../utils/UmfToast.js');
var app = getApp();
const YesterdayList = {
  //格式化数据
  _dataFormate: function (storeList) {
    let tradingVolumeArray = this.data.tradingVolume;
    //数据格式化
    for (let i = 0; i < storeList.length; i++) {
      let amount = umfUtils.fentoyuan(storeList[i]["sumAmount"]);
      storeList[i]["sumAmount"] = amount;
      tradingVolumeArray.push(storeList[i]);
    }
    //判断是否显示查看更多
    let hasMore = storeList.length === parseInt(app.globalData.pageSize);
    !hasMore && umfToast.showToast("已经加载完所有数据");
    this.setData({
      tradingVolume: tradingVolumeArray,
      hasMore: hasMore
    });
  }
}
export default YesterdayList;